import Vue from 'vue'
import App from './App.vue'
import Element from 'element-ui'
import VCharts from 'v-charts'

import router from './router'
import store from './store'
import 'element-ui/lib/theme-chalk/index.css'

Vue.config.productionTip = false

Vue.use(Element)
Vue.use(VCharts)

Vue.toast = Vue.prototype.$toast = (msg, type = 'success') => {
  Vue.prototype.$message({
    showClose: true,
    message: msg,
    type: type
  })
}

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
